using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;

namespace Xfinity.GameEditor
{
    public partial class OptionsPage : Form
    {
        public OptionsPage()
        {
            InitializeComponent();
        }

        private void splitContainer2_Panel2_Paint(object sender, PaintEventArgs e)
        {

        }

        private void OptionsPage_Load(object sender, EventArgs e)
        {
            propertyGrid.SelectedObject = Properties.Settings.Default;
            cancelButton.Enabled = false;
        }

        private void applyButton_Click(object sender, EventArgs e)
        {
            Properties.Settings.Default.Save();
            cancelButton.Enabled = false;
        }

        private void okButton_Click(object sender, EventArgs e)
        {
            Properties.Settings.Default.Save();
            Close();
        }

        private void cancelButton_Click(object sender, EventArgs e)
        {
            Close();
        }

        private void propertyGrid_Click(object sender, EventArgs e)
        {

        }

        private void propertyGrid_PropertyValueChanged(object s, PropertyValueChangedEventArgs e)
        {
            cancelButton.Enabled = true;
        }
    }
}